package com.zhouxiaoge.对象大小;

import jdk.nashorn.internal.ir.debug.ObjectSizeCalculator;

import java.util.ArrayList;
import java.util.List;

/**
 * @author 周小哥 gqzmy@163.com 2023/2/21 17:28
 */

public class Main {
    public static void main(String[] args) {
        Order order = new Order();
        long objectSize = ObjectSizeCalculator.getObjectSize(order);
        System.out.println(objectSize);

        List<Order> list = new ArrayList<>();
        list.add(new Order());
        list.add(new Order());
        long objectSize1 = ObjectSizeCalculator.getObjectSize(list);
        System.out.println(objectSize1);
    }
}
